import { writeText, readText } from "@tauri-apps/plugin-clipboard-manager";

export default () => {
  const write = async (text: string) => {
    return await writeText(text);
  };

  const read = async () => {
    const content = await readText();
    return content;
  };

  return {
    write,
    read,
  };
};
